<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
    <title>八维贷</title>
    <script src="https://unpkg.com/vue@2.6.14/dist/vue.min.js"></script>
    <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
    <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
    <script src="https://unpkg.com/element-ui/lib/index.js"></script>
    </head>
<body>
<div id="app">
    <center>
        <hr>
            <div align="right">
                欢迎{{mobile}},<a href="javascript:void(0)" @click="logout">[退出]</a>
            </div>
        <hr>
        <img src="logo.png" width="60%">
        <hr>
        <div>
            当前无授信额度
        </div>
        <hr>
        最高额度20W！<br><br>
        只需3步！！即可拥有！！<br><br>

        <div v-if="user.status==0">
            <a href="card.html">1、实名认证</a><br><br>
        </div>
        <div v-if="user.status>=1">
            1、实名认证【已完成】<br><br>
        </div>

        <div v-if="user.status<1">
            2、开立账户<br><br>
        </div>
        <div v-if="user.status==1">
            <a href="account.html">2、开立账户</a><br><br>
        </div>
        <div v-if="user.status>1">
            2、开立账户【已完成】<br><br>
        </div>

        <div v-if="user.status<2">
            3、额度审批<br><br>
        </div>
        <div v-if="user.status==2">
            <a href="workinfo.html">3、额度审批</a><br><br>
        </div>
        <div v-if="user.status>2">
            3、额度审批【已完成】<br><br>
        </div>

        <div v-if="user.status<3">
            4、发起借款<br><br>
        </div>
        <div v-if="user.status==3">
            <a href="account.html">4、发起借款</a><br><br>
        </div>
        <div v-if="user.status>3">
            4、发起借款【已完成】<br><br>
        </div>

        <div v-if="user.status<4">
            5、确认方案<br><br>
        </div>
        <div v-if="user.status==4">
            <a href="account.html">5、确认方案</a><br><br>
        </div>
        <div v-if="user.status>4">
            5、确认方案【已完成】<br><br>
        </div>

        <div v-if="user.status<5">
            6、等待放款<br><br>
        </div>
        <div v-if="user.status>5">
            6、放款完成<br><br>
        </div>

        <hr>

        <div style="width: 100%;position: absolute;bottom: 0">
            <hr>
            www.bwyjs.com @
            云计算1810A
            <hr>
        </div>

    </center>
</div>
<script>
    new Vue({
        el:'#app',
        data() {
            return {
                mobile:'',
                user:{
                    realname:'',
                    idacard:'',
                    status:0
                }
            };
        },
        methods: {
            logout(){
                localStorage.removeItem("mobile")
                location.href="index.html"
            }
        },
        created(){
            this.mobile = localStorage.getItem("mobile");

            if(this.mobile==undefined){
                location.href="index.html"
            }

            axios.get("/getUserInfo/"+this.mobile).then((res)=>{
                this.user = res.data;
            })
        }
    })
</script>
</body>
</html>